//导入路由
import VueRouter from 'vue-router'
// 导入路由组件
import HomeContainer from './componens/tabbars/HomeContainer.vue'
import MemberContainer from './componens/tabbars/MemberContainer.vue'
import ShopcarContainer from './componens/tabbars/ShopcarContainer.vue'
import SearchContainer from './componens/tabbars/SearchContainer.vue'
import NewsList from './componens/news/NewsList.vue'
import NewsInfo from './componens/news/NewsInfo.vue'
import PhotoList from './componens/photos/PhotoList.vue'
import PhotoInfo from './componens/photos/PhotoInfo.vue'
import GoodsList from './componens/goods/GoodsList.vue'
import GoodsInfo from './componens/goods/GoodsInfo.vue'
import GoodsDesc from './componens/goods/GoodsDesc.vue'
const router = new VueRouter({
    routes: [
        {path: '/',component: HomeContainer},
        {path: '/home',component: HomeContainer},
        {path: '/member',component: MemberContainer},
        {path: '/shop',component: ShopcarContainer},
        {path: '/search',component: SearchContainer},
        {path: '/home/news',component: NewsList},
        {path: '/home/newsinfo/:id',component: NewsInfo,props:true},
        {path: '/home/photo',component: PhotoList},
        {path: '/home/photoinfo/:id',component: PhotoInfo,props:true},
        {path: '/home/goodslist', component: GoodsList},
        {path: '/home/goodsinfo/:id',component: GoodsInfo,props: true},
        {path: '/home/goodsdesc/:id',component: GoodsDesc,props: true}
    ],
    linkActiveClass: 'mui-active' // 手动设置 被激活的  路由链接高亮  (这个属性是：路由跳转时动态添加样式)
})

//把router暴露出去
export default router
